-
Notifications
You must be signed in to change notification settings - Fork 658
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Draft] Network retriever module #3374
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
evan-schott
changed the title
[Draft PR] Network retriever module
[Draft] Network retriever module
Nov 4, 2023
evan-schott
force-pushed
the
feat/stubs-disassembler
branch
from
November 4, 2023 02:14
087f511
to
5b0459a
Compare
evan-schott
force-pushed
the
feat/network-retriever
branch
from
November 4, 2023 18:40
6982c5a
to
b1c9e93
Compare
d0cd
requested changes
Nov 21, 2023
@@ -42,8 +42,53 @@ impl<'a> CodeGenerator<'a> { | |||
program_string.push('\n'); | |||
} | |||
|
|||
// Import stub programs | |||
program_string.push_str(&input.stubs.values().map(|stub| self.visit_stub(stub)).join("\n")); | |||
// Create directed graph representation of program dependencies. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could the Retriever
module insert the stubs in the appropriate order?
evan-schott
force-pushed
the
feat/stubs-disassembler
branch
from
November 30, 2023 23:49
5b0459a
to
c94c2c3
Compare
…iever/src/lib.rs` to see it in action
evan-schott
force-pushed
the
feat/network-retriever
branch
from
December 2, 2023 00:21
574ae0a
to
db20544
Compare
d0cd
approved these changes
Dec 2, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
.leo
source files.Components:
program.json
leo build
leveragesretriever
module to pull programs from network/FSleo.lock
file to house the dependency configurationdisassembler.rs
to convert Aleo instructions into valid stubRetriever Design
Modifications to
~/.aleo
file structure.aleo/registry
:.aleo/registry/git
: Where.aleo
files fromgithub.com
are stored.aleo/registry/testnet3
: Where.aleo
files from the network are stored./mainnet
Suppose building leo project
dex
and callleo build
withdex/program.json
set to:Specification and example flow
dex/program.json
:"location": "network"
:credits.aleo
cached already in~/.aleo/registry/testnet3/credits.aleo
leo.lock
"location": "local"
: TODO"path": "~/work/board"
) if no aleo program in~/work/board/build/main.aleo
~/work/board/build/main.aleo
.aleo
and updateleo.lock
"location": "git"
: TODO"url": "<https://github.com/alice/foo.git>"
board.aleo
cached already as~/.aleo/registry/git/pranav/foo/board.aleo
dex/build/imports/
main.leo
Suggested user behavior
leo add credits.aleo
kicks off network retrieval + caching processgit
orlocal
tooprogram.json
{project}/build/imports/
as that is regenerated every timebuild
is invoked.~/.aleo/
&leo.lock
Future features
Leo add {program}
CLI